import request from '@/request'


/**
 * 批量添加学生
 * @param {*} studentList 
 * @returns 
 */
export function addMutiStudent(studentList) {
  return request({
    url: `/backend/student/add`,
    method: 'post',
    data: [{
      "clazz": "null",
      "college": 512,
      "discipline": "null",
      "gender": "male",
      "grade": 2019,
      "graduate": 2023,
      "id": "1",
      "identification": "null",
      "name": "wzf",
      "nationality": "null",
      "phone": "null",
      "status": "null",
      "trainingLevel": "null"
    }]
  })
}

/**
 * 分页获取所有学生信息
 * @param {*} page 
 * @param {*} pageSize 
 * @returns 
 */
export function getStudentByPage(page, pageSize) {
  return request({
    url: `/backend/student/list/${page}/${pageSize}/:asc`,
    method: 'get'
  })
}

export function searchStudentByPage(field, value) {
  return request({
    url: `/backend/student/find/${field}/${value}`,
    method: 'get'
  })
}